-
Notifications
You must be signed in to change notification settings - Fork 1.4k
feature: Live Activity #2191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
feature: Live Activity #2191
Conversation
Bump version to 3.5.0 to signify dev branch
|
Love the draft/prototype! Would love to see this make it into the project down the line I think it looks amazing! |
|
Built onto my real phone. Thanks so much for making this available. 👍 |
|
I have been using this for several days - I really enjoy having it attached to Loop. Bug report:
Feature requests:
|
|
Thanks for all the feedback:
Preview
|
|
Nice upgrade except the override appears confused.
|
|
The walking override started at 1:47 with a duration of 3 hours and was cancelled 19 minutes later.
|
|
I did a bit more testing.
|
StatusLive Activity controls work as expected. TestTest again with the latest updates. Focus on the whether the configuration displays the just-modified selections after a change. (Before they were enacted, but the screen did not update right away.) ConfigurationIPhone SE 3rd gen, running iOS 18.3.2
Test Save Button and Configuration DisplayThe Save button acts appropriately again (see this comment for details). This behavior is related to iOS 18 - older tests for this PR were with iOS 17. Initially, the Live Activity screen Save button was inactive
Comprehensive Tests for Save Button and Configuration DisplayTests below include looking at the Live Activity on the Lock Screen. For "success", the LA must match the displayed configuration. Repeat test for all rows on the Live Activity screen:
Test Bottom Row configuration screenTests below include looking at the Live Activity on the Lock Screen. For "success", the LA must match the displayed configuration.
|
marionbarker
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I commented on the need to use Loop.xcconfig to change IPHONEOS_DEPLOYMENT_TARGET. Withdrawing approval until that is updated.
|
@marionbarker Change request is pushed! |
Resolution NeededThis code does not build as is because of 2 problems. Once I resolved both of these in my local copy of your feat/live-activity branch, the code built and live-activity is displayed on my test phone (SE 3rd generation).
This is from dev branch, and those lines are also there in feat/live-activity branch (at lines 5085 and 5195). The lines with hard-coded values in |
|
It's ok to remove IPHONEOS_DEPLOYMENT_TARGET settings in this PR. |
|
@marionbarker fixed! branch is up-to-date with dev and removed the extra |
marionbarker
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Status
All good. LGTM.
Test
Begin with LoopWorkspace dev clone.
In Loop, switch to this branch and rebuild.
Build works as expected.
When built on a phone that supports Dynamic Island, the glucose shows up in the Dynamic Island when Live Activity is enabled.
The Live Activity, on the Lock Screen, works for
- SE 3rd running iOS 18.3.2
- iPhone 8 running iOS 16.7.10
|
Colors should match the Loop standard colors; glucose should not be orange, for example. The glucose graph colors should match the normal Loop graph colors if possible. The weight of the glucose points should be adjusted for the more dense display (right now all the green dots run into each other), and the forecast should be thin long dashed lines. We generally try to avoid jargon like "IOB" and "COB" in the app. I know it might take some redesign to fit it, but we've tried to maintain this, even on the tiny watch interface. IOB -> Active Insulin Thanks! |
|
Thank you, Bastiaan and Marion, for developing and adding the Live Activity feature to the Loop. It’s a great addition to the app. |
|
Hi @ps2 - A question as I'm working on this:
Do you object to different glucose colors being an option, but not the default? I've updated the code to use the standard Loop blue for the glucose points and prediction line (which also now match the main graph style better), but Bastiaan's code exposes a user option for color-coding the glucose points based on whether they are high, low, or in-range. A possible middle ground would be to retain that color coding only for the display of the current BG number below the graph, but not the graph points themselves. That could be handy for glanceability, including in the CarPlay display when driving, and on the Watch Smart Stack. There's no graph in those views, but seeing the color of the BG number out of the corner of your eye while driving would tell you whether or not you're in range, even if you don't read the number itself. I'm working on the other issues you flagged, and hope to share something soon. @bastiaanv, is it simplest for me to PR possible changes against your branch? Then if you merge, changes would automatically feed into this PR? Or let me know if another route is preferable. |
|
@elnjensen A PR against my branch would be the simplest flow yes. I will resolve any merge conflicts that are currently present on this PR afterwards |
Live activity edits
|
Update by @elnjensen!
Changes: |














This PR is an initial/basic version of this Live Activity, without any feature which are spoken of in the Zulipchat.
Look & Feel:
Lock Screen (all iPhone's):
Dynamic Island (iPhone 14 pro max and higher):
Settings
Things to know:
CurrentBG,IOB,COB,UpdatedAt(like in the screenshots)GlucoseStore.glucoseSamplesDidChangeCarbStore.carbEntriesDidChangedosing changingUIApplication.willEnterForegroundNotification